package com.woniuxy.service;

import com.woniuxy.demo.Result;
import com.woniuxy.dto.commonDto.BaseDto;
import com.woniuxy.dto.DistributorDtos;
import com.woniuxy.entity.Distributor;
import com.baomidou.mybatisplus.extension.service.IService;
import com.woniuxy.param.DelDistributorParam;
import com.woniuxy.param.DistributorAddPagram;
import com.woniuxy.param.DistributorPageParam;
import com.woniuxy.param.DistributorupdateParam;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;

/**
 * <p>
 * 渠道商 服务类
 * </p>
 *
 * @author zcx, ftl, gr, rhs
 * @since 2022-01-04
 */
public interface DistributorService extends IService<Distributor> {
    /**
     * 分页查询渠道商
     *
     * @param dp
     * @return
     */
    BaseDto<DistributorDtos> getDistributors(DistributorPageParam dp);

    /**
     * 删除
     *
     * @param ids
     * @return
     */
    boolean deldistributor(List<Integer> ids);

    /**
     * 修改
     *
     * @param dp
     * @return
     */
    boolean updatedistributor(DistributorupdateParam dp);

    /**
     * 新增
     *
     * @param dap
     * @return
     */
    boolean adddistributor(DistributorAddPagram dap);

    /**
     * 根据id查询渠道商
     *
     * @param distributorId
     * @return
     */
    DistributorDtos findDistributorById(Integer distributorId);
}
